﻿using System;
using System.Collections;
using System.Text;
using System.Configuration;
using System.Xml;
using System.Collections.Generic;

namespace Tree.Configuration
{
    public class ContainerConfiguration : ConfigurationSection
    {
        [ConfigurationProperty("collection", IsDefaultCollection = false)]
        [ConfigurationCollection(typeof(ContainerCollection),
            AddItemName = "add",
            ClearItemsName = "clear",
            RemoveItemName = "remove")]
        public ContainerCollection Collection
        {
            get
            {
                ContainerCollection container =
                    (ContainerCollection)base["collection"];
                return container;
            }
        }

        [ConfigurationProperty("earlyLoad", IsRequired = false)]
        public bool EarlyLoad
        {
            get { return Convert.ToBoolean(base["earlyLoad"]); }
        }
    }    
}